[#include "/WEB-INF/pages/common/taglibs.ftl"]
[#macro _script]
	<link rel="stylesheet" href="[@c.url value='/js/plugins/jquery-ztree/css/zTreeStyle/zTreeStyle.css'/]" type="text/css">
	<script type="text/javascript" src="[@c.url value='/js/plugins/jquery.alerts.js'/]"></script>
	<script type="text/javascript" src="[@c.url value='/js/plugins/jquery-ztree/js/jquery.ztree.core-3.1.js'/]"></script>
	<script type="text/javascript">
		var base = (function(){
			// 事件绑定
			function _addEventListeners() {
				var id = $(this).parent().attr('tval');
					var title = $('#delete-confirm').attr('title');
					var content = $('#delete-confirm').html();
			}
			// 页面渲染
			function _treeRender () {
				
			}
			return {
                config: {
                	url : null,
                    theme: null
                },
                init: function () {
                	_addEventListeners();
                	_treeRender();
                }
			}
		}());
		
		$(function(){
			var link = "[@c.url value='/manage/Navi_list.action?currentPage=${currentPage}'/]";
			base.config.theme = getTheme();
			base.config.url = link;
            //Initializing the form
			base.init();
		})
	</script>
[/#macro]
	<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
		<title>Insert title here</title>
		<meta name="navi" content="AdminNavi"/>
		<meta name="heading" content="heading"/>
		<style type="text/css">
			.navi_body {
				padding:12px;
				margain:0, 12px;
			}
			.navi_form {
				
			}
		</style>
		[@_script /]
	</head>
	<body id="body" class="navi_body">
		<br />
		<div class="contenttitle radiusbottom0" style="margin-bottom:1px;">
	    	<h2 id="vertical" class="form"><span>菜单自动生成</span></h2>
	    </div><!--contenttitle-->
    	<div class="wizard verwizard2" >
        	<div class="verticalmenu widgetbox anchor" style="width:320px;">
        		<!--tree--> 
        		<div class="widgetcontent announcement" style="overflow:auto;">
					<form action="[@c.url value='/manage/Navi_gen.action' /]" method="post" class="stdform stdform2">
						<p style="margin:1px 2px;">
							<span style="width:100%;">
								<label for="allAuto">按全部频道创建</label><input id="allAuto" name="type" type="radio" value="custom" /><br />
        						<label for="customAuto">按指定频道创建</label><input id="customAuto" name="type" type="radio" value="custom"  />
        						<select name="pid" class="atomic" style="width:64px;display:none;">
			                		<option value=""></option>
				                	[#list naviList as m]
			                		<option value="${(m.id)?c}" [#if (navi.id)?? && m.id == navi.id]selected="selected"[/#if]>${m.title}</option>
				                	[/#list]
			                	</select>
        					</span>
						</p>
			            <p class="stdformbutton">
			            	<button class="submit radius2">提交</button>
			                <input type="reset" value="重置" class="reset radius2">
			            </p>
			        </form>
        		 </div>
		    </div>
		</div>
	    <div id="info-confirm" style="display:none" title="菜单创建">
			<p>菜单删除后将无法恢复.您确认删除吗？</p>
		</div>
	</body>
	</html>
